package com.qyl.honghengshop.service.impl;

import java.util.List;

import com.qyl.honghengshop.dao.AdminUserDao;
import com.qyl.honghengshop.dao.impl.AdminUserDaoImpl;
import com.qyl.honghengshop.dto.User;
import com.qyl.honghengshop.service.AdminUserService;
import com.qyl.honghengshop.utils.PageBean;

public class AdminUserServiceImpl implements AdminUserService {

	private AdminUserDao adminUserDao = new AdminUserDaoImpl();
	
	@Override
	public void getUserList(PageBean pageBean,User user) {

		adminUserDao.getUserList(pageBean,user);

	}
	
	@Override
	public int getRecordCountByUser(User user) {

		return adminUserDao.getRecordCountByUser(user);
	}

	@Override
	public int addUser(User user) {

		int count = adminUserDao.addUser(user);
		
		return count;
	}

	@Override
	public void delUser(Integer id) {

		adminUserDao.delUser(id);
		
	}

	@Override
	public User getUserById(Integer id) {

		User updateUser = adminUserDao.getUserById(id);
		
		return updateUser;
	}

	@Override
	public int update(User user) {

		int count = adminUserDao.update(user);
		
		return count;
	}

	@Override
	public int delBatchUser(int[] ids) {

		
		return adminUserDao.delBatchUser(ids);
	}

	@Override
	public void updateUserHead(User user) {

		adminUserDao.updateUserHead(user);
		
	}

	@Override
	public void register(User user) {
		// TODO Auto-generated method stub
		
		adminUserDao.register(user);
		
	}

	@Override
	public void activeUser(String activeCode) {

		adminUserDao.activeUser(activeCode);
		
	}



}
